#pragma once
#include "resource.h"
#include "ToyotaPJ.h"
#include "defs.h"


unsigned __int16 CheckDsDataInfo(tt_Token *token, DsSt *DsInfo);
unsigned __int16 GetDataMonitorListP3(int CurSysIndex, tt_Token *token, DsSt *DsInfo);
int SendCmdAndGetPid(int CurSysIndex, tt_Token *token, DsSt *DsInfo);
int AnalyzeDsCmdDataP3(int pids, unsigned __int8 *pRcv, unsigned __int16 a3, DsSt *DsInfo);
int GetDSCmdDataInfoP3(int A1, unsigned __int8 *pCmd, EcuSt **a3, tt_Token *token, DsSt *Dsinfo);
int GetEnablePidListP3(int CurSysIndex, tt_Token *token, DsSt *DsInfo);
int HideDataMonitor(int ID, tt_Token *token);
unsigned __int16 PidCheckSupportP3(unsigned __int8 *EcuData, int *ValA, tt_Token *token, DsSt *DsInfo);
unsigned __int16 PidCheckSupportBitP3(int CalVal1, int a2, int a3, int a4, unsigned __int8 *a5, tt_Token *token, DsSt *DsInfo, int *a8);
unsigned __int16 GetDataMonitorListP5(int CurSysIndex, tt_Token *token, DsSt *DsInfo);

unsigned int P5_DidAnalyzeFrameData(unsigned int result, unsigned __int8 *pRecv, int a3, int a4, int a5, DSInofo4C *Ds4CInfo);
int P5_SendCmdCreateEnableRIdList(int SysOffset, DSInofo4C *Ds4CInfo, tt_Token *token);
int GetEnablePidListP5(int a1, int a2, DSInofo4C *Ds4CInfo, tt_Token *token, DsSt *DsInfo);
int GetDataIdBitForDmResRecord(int a1, int *a2, tt_Token *token);
int GetDataIdForDmResRecord(int a1, int *a2, tt_Token *a3);
int PidCheckSupportBitP5(int a1, int a2, int a3, int a4, unsigned char *a5, tt_Token *token, int a7, int *a8);
int SearchTestingCommand(tt_Token *a1, unsigned __int8 *RcvBuf, unsigned __int8 *CmdBuf, int Size);
int PidCheckSupportP5(unsigned __int16 *a1, int *a2, DSInofo4C *Ds4CInfo, tt_Token *token, DsSt *DsInfo);
int SaveTestingCommand(tt_Token *token, unsigned __int8 *RecvBuf, unsigned __int8 *Buf, int len, size_t _0);
int GetEnablePidListDK(int CurSysIndex, tt_Token *token, DsSt *DsInfo);
unsigned __int16 GetDsPidRecordDataPSA(tt_Token *token, DsSt *DsInfo);
unsigned int GetPidCommLengthPSA(int a1, int a2, unsigned __int8 *pCmd, tt_Token *token, unsigned __int8 *a5, _BYTE *a6);
int ShowDsItemMenu(int a1, DsSt *DsInfo, tt_Token *token);
int ShowSubMenuAndGetSelect(DsSt *DsInfo, int ItemIndex);
unsigned __int16 GetDataMonitorListDK(int CurSysIndex, tt_Token *token, DsSt *DsInfo);
unsigned __int16 GetDsPidRecordDataDK(EcuSt **EcuArr, DsSt *DsInfo);
unsigned __int16 GetDataMonitorListPSA(SysListInfoSt *SysInfo, tt_Token *token, DsSt *DsInfo);
unsigned __int16 GetDataMonitorListOldBody(int CurSysIndex, tt_Token *token, DsSt *DsInfo);
int PidCheckSupportOldBody(unsigned __int8 *Data, int *Val, tt_Token *token, DsSt *DsInfo);
int GetEnablePidListP4(int SysIndex, tt_Token *token, DsSt *a3);
int PidCheckSupportBitOldBody(int a1, int a2, int a3, int a4, unsigned __int8 *a5, DsSt *DsInfo, tt_Token *a7, int *a8);
unsigned __int16 GetDataMonitorListP4(int SysIndex, tt_Token *token, DsSt *DsInfo);
int GetDSCmdDataInfoP4(EcuSt **EcuDataArr, DsSt *DsInfo);
int PidCheckSupportP4(unsigned __int8 * EcuData, int *Val, DsSt *DsInfo);
unsigned __int16 CheckFreezeAllSupport(int a1, tt_Token *a2);
int MulPidCheckSupportP3(unsigned __int8 *EcuData, int *Val, tt_Token *token, DsSt *info);
unsigned __int16 PidCheckSupportBitP4(int a1, unsigned int a2, unsigned int a3, int *a4, DsSt *a5);
unsigned __int16 GetDataMonitorListMultiDidP4(int SysIndex, tt_Token *token, DsSt *DsInfo);
unsigned __int16 GetDataMonitorListMultiDidP3(int SysIndex, tt_Token *token, DsSt *DsInfo);











